#ifndef COMPLEXE_H
#define COMPLEXE_H

#include "constante.h"
#include "noncomplexnumber.h"
#include "entier.h"
#include "reel.h"
#include "rationnel.h"
#include "operation.h"
#include <iostream>
using namespace std;
class Complex : public Constante
{
        NonComplexNumber* real, *img;
public:
    Complex();
    Complex(const Complex&);
    Complex(const Integer&);
    Complex(const Fraction&);
    Complex(const Real&);
    Complex(const NonComplexNumber*,const NonComplexNumber* = new Integer(0));
    ~Complex();


    Constante* operator+(const Constante&)const;
    Constante* operator*(const Constante&)const;
    Constante* operator-(const Constante&)const;
    Constante* operator/(const Constante&)const;
    Constante* operator-()const;

    std::string print()const {
        std::stringstream ss;
        ss <<real->print()<<" + "<< this->img->print() << "*i";
        return ss.str();
    }

    NonComplexNumber* getReal(){return real;}
    NonComplexNumber* getImg(){return img;}


};

#endif // COMPLEXE_H
